home *** CD-ROM | disk | FTP | other *** search
/ Visual Basic Source Code / Visual Basic Source Code.iso / vbsource / painte1a / frmlogin.frm (.txt) < prev    next >
Visual Basic Form  |  1999-09-07  |  3KB  |  89 lines

  1. VERSION 5.00
  2. Begin VB.Form frmLogin 
  3.    BorderStyle     =   3  'Fixed Dialog
  4.    Caption         =   "Login..."
  5.    ClientHeight    =   1785
  6.    ClientLeft      =   45
  7.    ClientTop       =   330
  8.    ClientWidth     =   4755
  9.    Icon            =   "frmLogin.frx":0000
  10.    LinkTopic       =   "Form1"
  11.    MaxButton       =   0   'False
  12.    MinButton       =   0   'False
  13.    ScaleHeight     =   1785
  14.    ScaleWidth      =   4755
  15.    ShowInTaskbar   =   0   'False
  16.    StartUpPosition =   2  'CenterScreen
  17.    Tag             =   "Login"
  18.    Begin VB.CommandButton cmdCancel 
  19.       Cancel          =   -1  'True
  20.       Caption         =   "Cancel"
  21.       Height          =   360
  22.       Left            =   2610
  23.       TabIndex        =   3
  24.       Tag             =   "Cancel"
  25.       Top             =   1380
  26.       Width           =   1140
  27.    End
  28.    Begin VB.CommandButton cmdOK 
  29.       Caption         =   "OK"
  30.       Default         =   -1  'True
  31.       Height          =   360
  32.       Left            =   1005
  33.       TabIndex        =   2
  34.       Tag             =   "OK"
  35.       Top             =   1380
  36.       Width           =   1140
  37.    End
  38.    Begin VB.TextBox txtPassword 
  39.       Height          =   285
  40.       IMEMode         =   3  'DISABLE
  41.       Left            =   1800
  42.       PasswordChar    =   "*"
  43.       TabIndex        =   1
  44.       Top             =   780
  45.       Width           =   2325
  46.    End
  47.    Begin VB.Label Label1 
  48.       Alignment       =   2  'Center
  49.       Caption         =   $"frmLogin.frx":0442
  50.       Height          =   645
  51.       Left            =   75
  52.       TabIndex        =   4
  53.       Top             =   75
  54.       Width           =   4515
  55.    End
  56.    Begin VB.Label lblLabels 
  57.       Caption         =   "&Password:"
  58.       Height          =   255
  59.       Index           =   1
  60.       Left            =   600
  61.       TabIndex        =   0
  62.       Tag             =   "&Password:"
  63.       Top             =   795
  64.       Width           =   1080
  65.    End
  66. Attribute VB_Name = "frmLogin"
  67. Attribute VB_GlobalNameSpace = False
  68. Attribute VB_Creatable = False
  69. Attribute VB_PredeclaredId = True
  70. Attribute VB_Exposed = False
  71. Public OK As Boolean
  72. Private Sub cmdCancel_Click()
  73.     OK = False
  74.     Me.Hide
  75. End Sub
  76. Private Sub cmdOK_Click()
  77.     'ToDo: create test for correct password
  78.     'check for correct password
  79.     If txtPassword.Text = "catzndogz" Then
  80.         OK = True
  81.         Me.Hide
  82.     Else
  83.         MsgBox "Invalid Password, try again!", , "Login"
  84.         txtPassword.SetFocus
  85.         txtPassword.SelStart = 0
  86.         txtPassword.SelLength = Len(txtPassword.Text)
  87.     End If
  88. End Sub
  89.